<%direct_offers = Trade.find(:all, :conditions=>["game_id=? AND direct_player_id=?", @game.id, @player.id])%>
<%if direct_offers.size>0%>
  <h3>Direct Offer</h3>
  <table width="95%" style="border: 3px solid black; font-size: 18px;">
    <tr align="center" style="border: 3px solid black;" bgcolor="#cccccc">
      <th>Creditor</th><th>Price</th><th>Credit</th><th>Quantity</th><th></th>
    </tr>
    <%direct_offers.each do |dof|%>
    <tr align="center">
      <td align="left"><%=Player.find(dof.player_id).name%></td>
      <td><%=dof.price%></td>
      <td><%=dof.credit_term%></td>
      <td><%=number_with_delimiter(dof.quantity)%></td>
      <td>
        <a href="/user/accept_direct_offer/<%=dof.id%>">OK</a>
        <a href="/user/reject_direct_offer/<%=dof.id%>">Cancel</a>
      </td>
    </tr>
    <%end%>
  </table>
  <br/>
<%end%>